package com.finalproject.ui;
/**
 * DietaryProfile tab Panel
 */
import java.awt.BorderLayout;

import javax.swing.JPanel;
import com.finalproject.entity.CardHolderDatabase;

public class UIDietaryProfileTabPanel extends JPanel {

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;


	private UIDietaryProfile uiDietaryProfile;
	
	
	private UICardHolder uiCardHolder;
	
	private JPanel leftPanel;
	
	private JPanel rightPanel;
	
	private CardHolderDatabase cardHolderDatabase = CardHolderDatabase.getInstance();
	
	private UIDietarySummary uiDietarySummary;
	
	public UIDietaryProfileTabPanel() {
		super(new BorderLayout(5,5));
		leftPanel = new JPanel();
		leftPanel.setLayout(new BorderLayout());
		rightPanel = new JPanel();
		rightPanel.setLayout(new BorderLayout());
		
		
		add(leftPanel,BorderLayout.CENTER);
		add(rightPanel,BorderLayout.EAST);
		
		uiDietaryProfile = new UIDietaryProfile();
		//uiDietaryProfile.setBorder(BorderFactory.createTitledBorder("My Dietary Profile"));
		
		uiDietarySummary = new  UIDietarySummary();
		leftPanel.add(uiDietarySummary,BorderLayout.NORTH);
		UICardHolder uiCardHolder = new UICardHolder();
		rightPanel.add(uiCardHolder,BorderLayout.NORTH);
		rightPanel.add(uiDietaryProfile,BorderLayout.CENTER);
		rightPanel.setPreferredSize(UIConstants.RIGHT_PANEL_PREFERRED);
	}
}
